package cn.com.taurus.impl;

import cn.com.taurus.entity.Admins;
import cn.com.taurus.entity.PowerManager;
import cn.com.taurus.entity.Users;
import cn.com.taurus.mapper.PowerManagerMapper;
import cn.com.taurus.service.PowerManagerService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import java.util.List;
/**
 * @author zhy
 * @createTime 2021-6-3 20:49:18
 * @remark 用户Impl层
 * @version 1.0
 */
@Service
public class PowerManagerImpl implements PowerManagerService {
    @Autowired
    PowerManagerMapper powerManagerMapper;

    /**
     * 查询权限
     * @param aId
     * @return
     */
    @Override
    public List<PowerManager> selectPmNameByAId(Integer aId) {
        return powerManagerMapper.selectPmNameByAId(aId);
    }

    /**
     * 后台人员修改
     * @param powerManager 权限对象
     */
    public int updatePowerManager(PowerManager powerManager){
        return powerManagerMapper.updatePowerManager(powerManager);
    }


    /**
     * 查询后台人员信息
     * @return 权限功能和后台人员对象集合
     */
    public List<PowerManager> selectPowerManager(){
        return powerManagerMapper.selectPowerManager();
    }

    /**
     * 条件查询权限功能和后台人员信息
     * @param powerManager 权限对象
     * @return
     */
    public List<PowerManager> selectConditionPowerManager(PowerManager powerManager){
        return powerManagerMapper.selectConditionPowerManager(powerManager);
    }
}
